<?php

class Admin_Bootstrap extends Zend_Application_Module_Bootstrap
{

    
   protected function _initLayout()
   {

		$this->bootstrap('frontController');
	    $front = $this->getResource('frontController');
	    $front->setRequest(new Zend_Controller_Request_Http());
	    	
		$request = $this->frontController->getRequest()->getRequestUri() ;		
        $request = str_replace(Zend_Controller_Front::getInstance()->getBaseUrl(),'',$request);
        
		if ( '/admin' != substr($request,0,6) ){			
			return true;
            
		}
			
		  // Change layout
		  Zend_Layout::getMvcInstance()->setLayoutPath(APPLICATION_PATH.'/modules/admin/layouts/scripts/');
          Zend_Layout::getMvcInstance()->setLayout('layout');

    // return $layout;
   }

   
   protected function _initPlugins() {
  	    $front = Zend_Controller_Front::getInstance();
		include(APPLICATION_PATH.'/modules/default/plugins/basicInit.php');
		$front->registerPlugin(new Default_Plugin_BasicInit());
   }  
    
}

